<h3>Upload Applicant information from a Gradweb data download file.</h3>
<?php
if (isset($line_count) 
		&& isset($mal_rec_count) 
		&& isset($masters) ) {
	$good_count = $line_count - $mal_rec_count;
?>	
	
	<div class="input">
		<p>
			The file contained a total of <?php echo $line_count ?> lines.<br />
			Successfully processed a total of <?php echo $good_count ?> records. <br />
			There were a total of <?php echo $mal_rec_count ?> records with errors. <br /><br />
		</p>
		<p> 
			<?php foreach($masters as $rec) {
							echo $rec . '<br />';
						}
			?>
		</p>
		<p class="error_message">
			<?php foreach($errors as $rec) {
							echo $rec . '<br />';
						}
			?>
		</p>
	</div>
	
<?php 
} else { //user hasn't submitted the file. 
	echo $this->Form->create('User', array('type' => 'file', 'action' => 'upload'));
	echo $this->Form->input('file', array('label' => 'Gradweb Data file', 
																						 'type'=>'file',
																						 'error' => 'There was a problem uploading your file. 
																								 		Either the file was the wrong format or there 
																								 		was an internal error, please try again.'));
	echo $this->Form->end('Submit');		

} //end else.
?>